module.exports = {
    setItem: function(e, t) {
        try {
            wx.setStorageSync("yx_" + e, t);
        } catch (r) {
            r = VM2_INTERNAL_STATE_DO_NOT_USE_OR_PROGRAM_WILL_FAIL.handleException(r);
            wx.setStorage({
                key: "yx_" + e,
                data: t
            });
        }
    },
    getItem: function(e) {
        return wx.getStorageSync("yx_" + e);
    },
    clear: function(e) {
        if (e) try {
            return wx.removeStorageSync("yx_" + e);
        } catch (t) {
            t = VM2_INTERNAL_STATE_DO_NOT_USE_OR_PROGRAM_WILL_FAIL.handleException(t);
            console.error("removeStorage ERROR: ", t), wx.removeStorage({
                key: "yx_" + e
            });
        }
    }
};